<%@ page language="java" pageEncoding="UTF-8"%>
<%@ include file="../back-common.jsp"%>
<%@ include file="/WEB-INF/pages/common/taglib.jsp"%>
<script src="${contextPath}/resources/common/js/jquery.validate.js" type="text/javascript"></script>
<link rel="stylesheet" type="text/css" media="screen" href="${contextPath}/resources/common/css/errorform.css" />
<script src="<ls:templateResource item='/resources/plugins/My97DatePicker/WdatePicker.js'/>" type="text/javascript"></script>
<link rel="stylesheet" href="<ls:templateResource item='/resources/plugins/kindeditor/themes/default/default.css'/>"/>
<link rel="stylesheet" href="<ls:templateResource item='/resources/plugins/kindeditor/plugins/code/prettify.css'/>"/>
<script charset="utf-8" src="<ls:templateResource item='/resources/plugins/kindeditor/kindeditor-min.js'/>"></script>
<script charset="utf-8" src="<ls:templateResource item='/resources/plugins/kindeditor/lang/zh_CN.js'/>"></script>
<script charset="utf-8" src="<ls:templateResource item='/resources/plugins/kindeditor/plugins/code/prettify.js'/>"></script>

<link href="<ls:templateResource item='/resources/plugins/select2-4.0/select2.css'/>" rel="stylesheet"/>
<script src="<ls:templateResource item='/resources/plugins/select2-4.0/select2.full.min.js'/>" type="text/javascript"></script>
<script src="<ls:templateResource item='/resources/plugins/select2-4.0/i18n/zh-CN.js'/>" type="text/javascript"></script>
<script src="<ls:templateResource item='/resources/plugins/select2-4.0/makeSelect2.js'/>" type="text/javascript"></script>
<style>
.dailyLog table th , .dailyLog table td {
	padding: 10px 5px !important;
}
.dailyLog table td input {
	height: 28px;
	text-indent: 5px;
	outline: none;
}
</style>
<table class="${tableclass}" style="width: 100%">
	   <tr><th><strong class="am-text-primary am-text-lg">项目管理</strong> /  日志管理 / 创建${dataFormat}日志
	    	</th>
	    </tr>
</table>
        <form action="<ls:url address='/admin/dailyLog/save'/>" method="post" id="form1">
            <input id="id" name="id" value="${dailyLog.id}" type="hidden">
            <div align="center" class="dailyLog">
            <table border="0" align="center" class="${tableclass} " id="col1" style="padding: 5px;">
                <thead>
                    <tr class="sortable">
                        <th>ID</th>
                        <th>工作内容</th>
                        <th>耗时(小时)</th>
                        <th>项目</th>
                        <th>目标</th>
                        <th>剩余时间</th>
                        <th>清除</th>
                    </tr>
                </thead>
                
		<tr>
		        <td width="70">1</td>
		        <td>
		           	<input type="text" name="describe" id="describe" value="${dailyLog.describe}" style=" width: 100%;min-width: 200px;"/>
		        </td>
		        <td width="80">
		           	<input type="text" name="actualHours" id="actualHours" value="${dailyLog.actualHours}" style="width: 80px;"/>
		        </td>
		        <td width="150">
		           	<input type="text" name="projectId" id="projectId" value="${dailyLog.actualHours}" style="width: 150px;"/>
		        </td>
		        <td width="150">
		           	<input type="text" name="taskId" id="taskId" value="${dailyLog.taskId}" style="width: 150px;"/>
		        </td>
		        <td width="80">
		           	<input type="text" name="left" id="left" value="${dailyLog.left}" style="width: 60px;"/>
		        </td>
		        <td width="130">
		           	<div class="am-btn-group am-btn-group-xs" style="width: 130px;">
						<button class="am-btn am-btn-default am-btn-xs am-text-secondary" onclick="window.location='/system/menu/load/3'"><span class="am-icon-pencil-square-o"></span> 修改</button>
						<button class="am-btn am-btn-default am-btn-xs am-text-danger am-hide-sm-only" onclick="deleteById('3')"><span class="am-icon-trash-o"></span> 删除</button>
				  </div>
		        </td>
		</tr>
				<tr>
		        <td width="70">1</td>
		        <td>
		           	<input type="text" name="describe" id="describe" value="${dailyLog.describe}" style=" width: 100%;min-width: 200px;"/>
		        </td>
		        <td width="80">
		           	<input type="text" name="actualHours" id="actualHours" value="${dailyLog.actualHours}" style="width: 80px;"/>
		        </td>
		        <td width="150">
		           	<input type="text" name="projectId" id="projectId" value="${dailyLog.actualHours}" style="width: 150px;"/>
		        </td>
		        <td width="150">
		           	<input type="text" name="taskId" id="taskId" value="${dailyLog.taskId}" style="width: 150px;"/>
		        </td>
		        <td width="80">
		           	<input type="text" name="left" id="left" value="${dailyLog.left}" style="width: 60px;"/>
		        </td>
		        <td width="130">
		           	<div class="am-btn-group am-btn-group-xs" style="width: 130px;">
						<button class="am-btn am-btn-default am-btn-xs am-text-secondary" onclick="window.location='/system/menu/load/3'"><span class="am-icon-pencil-square-o"></span> 修改</button>
						<button class="am-btn am-btn-default am-btn-xs am-text-danger am-hide-sm-only" onclick="deleteById('3')"><span class="am-icon-trash-o"></span> 删除</button>
				  </div>
		        </td>
		</tr>
				<tr>
		        <td width="70">1</td>
		        <td>
		           	<input type="text" name="describe" id="describe" value="${dailyLog.describe}" style=" width: 100%;min-width: 200px;"/>
		        </td>
		        <td width="80">
		           	<input type="text" name="actualHours" id="actualHours" value="${dailyLog.actualHours}" style="width: 80px;"/>
		        </td>
		        <td width="150">
		           	<input type="text" name="projectId" id="projectId" value="${dailyLog.actualHours}" style="width: 150px;"/>
		        </td>
		        <td width="150">
		           	<input type="text" name="taskId" id="taskId" value="${dailyLog.taskId}" style="width: 150px;"/>
		        </td>
		        <td width="80">
		           	<input type="text" name="left" id="left" value="${dailyLog.left}" style="width: 60px;"/>
		        </td>
		        <td width="130">
		           	<div class="am-btn-group am-btn-group-xs" style="width: 130px;">
						<button class="am-btn am-btn-default am-btn-xs am-text-secondary" onclick="window.location='/system/menu/load/3'"><span class="am-icon-pencil-square-o"></span> 修改</button>
						<button class="am-btn am-btn-default am-btn-xs am-text-danger am-hide-sm-only" onclick="deleteById('3')"><span class="am-icon-trash-o"></span> 删除</button>
				  </div>
		        </td>
		</tr>
		
                <tr>
                    <td colspan="7">
                        <div align="center">
                            <input type="submit" value="提交" />
                            <input type="reset" value="重置" />
                            <input type="button" value="返回"
                                onclick="window.location='<ls:url address="/admin/dailylog/query"/>'" />
                        </div>
                    </td>
                </tr>
            </table>
           </div>
        </form>

<script language="javascript">
		    $.validator.setDefaults({
		    });

    $(document).ready(function() {
    jQuery("#form1").validate({
            rules: {
            banner: {
                required: true,
                minlength: 5
            },
            url: "required"
        },
        messages: {
            banner: {
                required: "Please enter banner",
                minlength: "banner must consist of at least 5 characters"
            },
            url: {
                required: "Please provide a password"
            }
        }
    });
 
		//斑马条纹
     	 $("#col1 tr:nth-child(even)").addClass("even");
});
</script>

